/**
 * Created by Administrator on 2015/4/28 0028.
 */
var userInfoModule=angular.module('userInfoModule',[]);
userInfoModule.controller('UserInfoCtrl',['$scope', function ($scope) {
    $scope.userInfo={
        email:"380076574@qq.com",
        password:"380076574",
        autoLogin:true
    };
    $scope.getFormData= function () {
        console.log($scope.userInfo);
    };
    $scope.setFormData= function () {
        $scope.userInfo={
            email:"346914457@qq.com",
            password:"346914457",
            autoLogin:false
        }
    };
    $scope.resetFormData= function () {
        $scope.userInfo={
            email:"380076574@qq.com",
            password:"380076574",
            autoLogin:true
        }
    };
    $scope.toggle= function () {
        $scope.userInfo.autoLogin=!$scope.userInfo.autoLogin;
        console.log($scope.userInfo.autoLogin);
    }
}]);


var validationApp=angular.module("validationApp",[]);
validationApp.controller("mainController",['$scope', function ($scope) {
    $scope.submit= function (isValid) {
        if(isValid){
            alert("good");
        }
        
    }

}]);